-
-
Notifications
You must be signed in to change notification settings - Fork 495
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(linter): eslint-plugin-vitest/require-local-test-context-for-concurrent-snapshots #4578
Conversation
Your org has enabled the Graphite merge queue for merging into mainAdd the label “merge” to the PR and Graphite will automatically add it to the merge queue when it’s ready to merge. Or use the label “hotfix” to add to the merge queue as a hot fix. You must have a Graphite account and log in to Graphite in order to use the merge queue. Sign up using this link. |
…oncurrent-snapshots
CodSpeed Performance ReportMerging #4578 will not alter performanceComparing Summary
|
…oncurrent-snapshots
…oncurrent-snapshots
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you split the bug fixes in another PR? We are supposed this PR only contains things about require-local-test-context-for-concurrent-snapshots
rule.
("testSomething()", None), | ||
("xitSomethingElse()", None), | ||
("xitiViewMap()", None), | ||
("describe('foo', function () {})", None, None, Some(PathBuf::from(jest_path))), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We don't need to change test cases in rules, you can update path at once:
let path_to_lint = if self.import_plugin {
assert!(path.is_none(), "import plugin does not support path");
self.current_working_directory.join(&self.rule_path)
} else if let Some(path) = path {
self.current_working_directory.join(path)
+ } else if self.jest_plugin {
+ self.rule_path.with_extension("test.tsx")
} else {
self.rule_path.clone()
};
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Okay, I'll updated it later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done.
This PR looks huge, can you split the bug fixes into another PR? |
support eslint-plugin-vitest/require-local-test-context-for-concurrent-snapshots